package com.cms.work.service.impl.transaction;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.cms.work.core.service.impl.BaseServiceImpl;
import com.cms.work.dao.transaction.IAssetFollowDao;
import com.cms.work.entity.transaction.AssetFollow;
import com.cms.work.service.transaction.IAssetFollowService;

/**
 * @describe 资产变更
 * @author YY
 * @version v1.0
 * @date 2016-11-24 21:02:49
 **/
@Service
public class AssetFollowServiceImpl extends BaseServiceImpl<AssetFollow, Integer> implements IAssetFollowService {
	
    @Autowired
    private IAssetFollowDao assetFollowDao;
	
	@Override
	public void save(AssetFollow assetFollow) {
	    if (assetFollow.getId() == null || assetFollow.getId() == 0) {
            assetFollowDao.insertSelective(assetFollow);
        } else {
            assetFollowDao.updateByPrimaryKeySelective(assetFollow);
        }
	}
}

